/*
 * Copyright 2021 The Slam Authors
 */

#ifndef SLAM_IO_TEXT_FILE_READ_WRITE_H_
#define SLAM_IO_TEXT_FILE_READ_WRITE_H_

#include <iostream>
#include <fstream>
#include <map>
#include <vector>
#include <jsoncpp/json/json.h>

namespace slam {
namespace io {

void SplitString(const std::string& str, const std::string& delimiter,
    std::vector<std::string>* result);

bool LoadDataFromTxt(const std::string& file_name,
    const std::string& delimiter,
    std::vector<std::vector<std::string>>* all_str_ptr);

bool LoadNavigationNodeFromJson(const std::string& file_name,
      std::vector<std::vector<std::string>>* navigation_node_ptr);

bool LoadNavigationEdgeFromJson(const std::string& file_name,
      std::vector<std::vector<std::string>>* navigation_edge_ptr);

bool LoadDataFromJson(const std::string& file_name,
    Json::Value* data);

}
}

#endif